import React from 'react';
import useMyReducer from '../../../reduce';
import { useNavigate } from 'react-router-dom'
const City = () => {
    const Naviagte = useNavigate()
    const {state}=useMyReducer()
    const city = {
        position: 'absolute',
        top: '0px',
        left: '10px',
        fontSize: '30px',
        color: '#ffaebd',
    }
    return (
        <div style={city} onClick={() => { Naviagte('/city') }}>
            {state.city} ▼
        </div>
    );
}

export default City;
